import sys,os
from random import randrange

#Class that helps generating the 7 types of bricks
class BrickCenter:
    def __init__(self):
        brick0=[(0,1),(1,1),(2,1),(2,2)]
        brick1=[(0,2),(1,2),(2,2),(2,1)]
        brick2=[(0,1),(1,1),(1,2),(2,2)]
        brick3=[(0,2),(1,2),(1,1),(2,1)]
        brick4=[(0,1),(1,1),(1,2),(2,1)]
        brick5=[(0,1),(1,1),(2,1),(3,1)]
        brick6=[(1,1),(1,2),(2,1),(2,2)]
        self.brickList=[]
        self.brickList.append(brick0)
        self.brickList.append(brick1)
        self.brickList.append(brick2)
        self.brickList.append(brick3)
        self.brickList.append(brick4)
        self.brickList.append(brick5)
        self.brickList.append(brick6)
        self.brickTypeCount=len(self.brickList)
        
    def GenerateNewBrick(self):
        index=randrange(0,self.brickTypeCount)
        return self.brickList[index]

#Testing    
if __name__ == "__main__":
    brickCenter=BrickCenter()
    count = 0
    while count <= 10:
        print count,'\t',brickCenter.GenerateNewBrick()
        count+=1